package com.mdg.bike;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;


public class BikeActivity extends Activity {
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
    
        /* Set up the listener for the directory button */
        Button coursesbtn = (Button) findViewById(R.id.dirbtn);
        coursesbtn.setOnClickListener(new View.OnClickListener() {
                        
                        public void onClick(View v) {
                                Intent myIntent = new Intent(v.getContext(), Directory.class);
                                startActivityForResult(myIntent, 0);
                        }
                });

        /* Set up the listener for the map button */
        Button parkingbtn = (Button) findViewById(R.id.mapbtn);
        parkingbtn.setOnClickListener(new View.OnClickListener() {
                        
                        public void onClick(View v) {
                                Intent myIntent = new Intent(v.getContext(), Map.class);
                                startActivityForResult(myIntent, 0);
                        }
        });
        
        /* Set up the listener for the timer button */
        Button sportsbtn = (Button) findViewById(R.id.timerbtn);
        sportsbtn.setOnClickListener(new View.OnClickListener() {
                        
                        public void onClick(View v) {
                                Intent myIntent = new Intent(v.getContext(), Timer.class);
                                startActivityForResult(myIntent, 0);
                        }
                });
    }
}